<?php

function load_class($name, $path)
{
    if (file_exists(APP_PATH . $path . '/' . $name . EXT))
    {
        require APP_PATH . $path . '/' . $name . EXT;
    }
    else
    {
        require SYS_PATH . $path . '/' . $name . EXT;
    }
}

function require_config_files()
{
    /* Merge the config files */
    require SYS_PATH . 'config/config.php';
    require APP_PATH . 'config/config.php';
    $_config = $config;
    unset($config);
    return $_config;
}